<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>class 类选择器示例:</title>
  <style type="text/css">
    .center {
      text-align: center;
      color: white;
      background-color: #771100;
    }
    .important {font-weight:bold;}
    .warning {font-style:italic;}
    .important.warning {background:silver;}  /**两个类选择器链接在一起**/
  </style>
</head>
<body>
<p><b>class 类选择器示例:</b></p>
<h1 class="center">
  This heading will be center-aligned
  </h1>
  <p class="center">
  This paragraph will also be center-aligned.
  </p>

<p><b>class 多类选择器示例:</b></p>
<p class="important warning">  
  /**这两个词的顺序无关紧要，写成 warning important 也可以**/
This paragraph is a very important warning.
</p>
<hr>
</body>
</html>